var status = -1;
var selectionLog = [];

function start(d, c, b) {
    status++;
    var a = -1;
    if (status <= a++) {
        qm.dispose()
    } else {
        if (status == a++) {
            qm.curNodeEventEnd(true);
            qm.setInGameDirectionMode(true, true, true);
            qm.inGameDirectionEvent_AskAnswerTime(1000)
        } else {
            if (status === a++) {
                qm.fieldEffect_PlayBGM("Bgm00.img/Silence", 0, 0);
                qm.fieldEffect_PlayBGM("Bgm18.img/BlackWing", 0, 0);
                qm.npc_ChangeController(1540443, "oid=22699400", -515, -350, 18, -565, -465, 1, false, 0, false);
                qm.npc_SetSpecialAction("oid=22699400", "summon", 0, 0);
                qm.npcMove(1540443, 500, 0, 0);
                qm.inGameDirectionEvent_AskAnswerTime(100)
            } else {
                if (status === a++) {
                    qm.onTeleport(0, 3, qm.getPlayer().getId(), -769, -161);
                    qm.inGameDirectionEvent_MoveAction(2);
                    qm.inGameDirectionEvent_AskAnswerTime(100)
                } else {
                    if (status === a++) {
                        qm.inGameDirectionEvent_MoveAction(0);
                        qm.npcMove(1540443, -500, 0, 7000);
                        qm.inGameDirectionEvent_AskAnswerTime(8000)
                    } else {
                        if (status === a++) {
                            qm.addPopupSay(1013203, 1000, "你们这些臭苍蝇!\r\n哈哈哈!", "", 0);
                            qm.inGameDirectionEvent_AskAnswerTime(1000);
                            qm.effect_Voice("Voice3.img/BlackHeaven/carrier/2", 100)
                        } else {
                            if (status === a++) {
                                qm.npc_SetSpecialAction("oid=22699400", "shoot", 0, 1);
                                qm.fieldEffect_PlayFieldSound("BlackHeaven/2", 100);
                                qm.inGameDirectionEvent_AskAnswerTime(2500)
                            } else {
                                if (status === a++) {
                                    qm.fieldEffect_InsertCanvas11(0, 256, 0, 0, 0, 0);
                                    qm.fieldEffect_InsertCanvas11(5, 0, 0, 0, 0, 0);
                                    qm.npc_LeaveField("oid=22699400");
                                    qm.npc_LeaveField("oid=22699400");
                                    qm.npc_ChangeController(1540602, "oid=22700054", -515, -350, 18, -565, -465, 1, false, 0, false);
                                    qm.npc_SetSpecialAction("oid=22700054", "summon", 0, 0);
                                    qm.addPopupSay(1540455, 1000, "趴下!!", "", 0);
                                    qm.inGameDirectionEvent_AskAnswerTime(500)
                                } else {
                                    if (status === a++) {
                                        qm.inGameDirectionEvent_QTE(4)
                                    } else {
                                        if (status === a++) {
                                            qm.fieldEffect_InsertCanvas11(0, 0, 0, 0, 0, 0);
                                            qm.inGameDirectionEvent_AskAnswerTime(1000)
                                        } else {
                                            if (status === a++) {
                                                qm.npc_LeaveField("oid=22700054");
                                                qm.npc_LeaveField("oid=22700054");
                                                qm.npc_ChangeController(1540603, "oid=22700105", -515, -350, 18, -565, -465, 1, false, 0, false);
                                                qm.npc_SetSpecialAction("oid=22700105", "summon", 0, 0);
                                                qm.npc_SetSpecialAction("oid=22700105", "special", 0, 1);
                                                qm.fieldEffect_PlayFieldSound("BlackHeaven/3", 100);
                                                qm.inGameDirectionEvent_AskAnswerTime(50)
                                            } else {
                                                if (status === a++) {
                                                    qm.inGameDirectionEvent_MoveAction(4);
                                                    qm.fieldEffect_Tremble(0, 500, 30);
                                                    qm.inGameDirectionEvent_AskAnswerTime(2000)
                                                } else {
                                                    if (status === a++) {
                                                        qm.inGameDirectionEvent_MoveAction(0);
                                                        qm.addPopupSay(1013203, 1000, "鼠窃狗盗之辈!", "", 0);
                                                        qm.inGameDirectionEvent_AskAnswerTime(1000);
                                                        qm.effect_Voice("Voice3.img/BlackHeaven/carrier/5", 100)
                                                    } else {
                                                        if (status === a++) {
                                                            qm.npcMove(1540603, 500, 0, 3000);
                                                            qm.inGameDirectionEvent_AskAnswerTime(3000)
                                                        } else {
                                                            if (status === a++) {
                                                                qm.npc_LeaveField("oid=22700105");
                                                                qm.npc_LeaveField("oid=22700105");
                                                                qm.addPopupSay(1540455, 1000, "跟着那家伙!", "", 0);
                                                                qm.inGameDirectionEvent_AskAnswerTime(3500)
                                                            } else {
                                                                if (status === a++) {
                                                                    qm.setInGameDirectionMode(false, true, false);
                                                                    qm.updateInfoQuest(33132, "save=5;boss=noclear;board1=Noclear");
                                                                    qm.updateInfoQuest(33132, "save=5;boss=noclear;board1=clear");
                                                                    qm.gainExp(576000);
                                                                    qm.updateInfoQuest(63311, "combo=58");
                                                                    qm.effect_GainExpGold(576000);
                                                                    qm.dispose();
                                                                    qm.enableActions()
                                                                }
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
};